package com.venus.mq.zk;

import org.I0Itec.zkclient.ZkClient;

/**
 * Created by mc on 18/11/21.
 */
public class ZkTest {

    public static void main(String[] args) {

        ZkClient zkClient = ZkConfig.getInstance();

        ZkService zkService = new ZkServiceImpl(zkClient);

        String zkPath = "/venus-mq";

        zkClient.createPersistent(zkPath);

        zkService.write(zkPath,"zk写入测试");

        Object object = zkService.read(zkPath);

        System.out.print("zk读取测试:"+object.toString());
    }
}
